#ifndef LOGIN_H
#define LOGIN_H

#include <QWidget>
#include <QTimer>
#include <QPainter>
#include <QPaintEvent>
#include <QtMath>
#include <QPoint>
#include <QDebug>

#include "widget.h"

namespace Ui {
class Login;
}

class Login : public QWidget
{
    Q_OBJECT

public:
    explicit Login(QWidget *parent = nullptr);
    ~Login();

    void paintEvent(QPaintEvent *);
    void drawYu(QPainter *painter);
    void drawGua(QPainter *painter);

private:
    QTimer *gtv_timer;
    int giv_angleStep;
    int giv_currentValue;
    int giv_maxValue;
    int giv_radius;
    QColor gcv_background;              //背景色
    QColor gcv_foreground;              //前景色
    int giv_count;

    QPixmap *pixmap;

    Widget *w;

private:
    double degreesToRadians(double degrees);

private:
    Ui::Login *ui;
};

#endif // LOGIN_H
